﻿using Abp;
using Abp.Castle.Logging.Log4Net;
using Abp.Dependency;
using AbpBuild.WenShu;
using Castle.Facilities.Logging;
using Microsoft.Owin.Hosting;
using MultipleDbContextEfCoreDemo.Services;
using System.Threading.Tasks;
namespace WenShuConsoleApp
{
    public class Program
    {
        static void Main(string[] args)
        {
            using (var bootstrapper = AbpBootstrapper.Create<CompanyConsoleAppModule>())
            {
                bootstrapper.IocManager.IocContainer
                    .AddFacility<LoggingFacility>(
                        f => f.UseAbpLog4Net().WithConfig("log4net.config")
                    );

                bootstrapper.Initialize();

                using (var caller = bootstrapper.IocManager.ResolveAsDisposable<CompanySearshAppService>())
                {
                   caller.Object.GetcompanyAQCConsole();
                }
            }
        }
    }
}
